package com.ruoyi.shopping.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 商品管理对象 commodity
 * 
 * @author ysq
 * @date 2024-08-14
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class Commodity extends BaseEntity
{
//    private static final long serialVersionUID = 1L;

    /** 商品id */
    private Long id;

    /** 商品名称 */
    @Excel(name = "商品名称")
    private String name;

    /** 商品描述 */
    @Excel(name = "商品描述")
    private String description;

    /** 商品价格 */
    @Excel(name = "商品价格")
    private Double price;

    /** 商品详情 */
    @Excel(name = "商品详情")
    private String details;

    /** 商品总库存 */
    @Excel(name = "商品总库存")
    private Long inventory;

    /** 商品销量 */
    @Excel(name = "商品销量")
    private Long sales;

    /** 商品种类id */
    @Excel(name = "商品种类id")
    private Long commodityCategoryId;

    /** 商品种类信息 */
    @TableField(exist = false)
    private CommodityCategory commodityCategory;
    @TableField(exist = false)
    private String commodityCategoryType;

    /** 商品图片实体 */
    @TableField(exist = false)
    private CommodityImages commodityImages;

    /** 删除 */
    private Long del;
}
